package com.thunder.component;

import java.awt.Color;
import java.awt.Font;
import java.awt.Graphics;
import java.awt.image.BufferedImage;

import com.thunder.utils.Constant;
import com.thunder.utils.GameUtil;

public class GameReady {
	private final BufferedImage image;
	private int sepline;

	public GameReady() {
		image = GameUtil.loadBufferedImage(Constant.START_IMG_PATH);
		sepline = 0;
	}
	
	public void draw(Graphics g) {
		g.drawImage(image, 0, sepline % 900, null);
		g.drawImage(image, 0, sepline % 900 - 900, null);
		sepline += Constant.Fly_Velocity;
		
		g.setColor(Color.white);
		g.setFont(new Font("楷体",Font.ITALIC, 40));
		g.drawString("按空格键进入游戏", 150,  600);
		
		
	}
}
